<?php
namespace app\admin\validate;

use think\Validate;

class ExamPaper extends Validate
{
    protected $rule = [
        'title'    => 'require',
        'duration' => 'require|integer|egt:1',
    ];
    protected $message = [
        'title.require' => '试卷标题不能为空',
        'duration.require' => '考试时长不能为空',
        'duration.integer' => '考试时长必须为整数',
        'duration.egt' => '考试时长不能小于1分钟',
    ];
}
